package T01_test_all.test04_Phone;

public class test04_phone {
//    公共类
    String brand;
    double price;
//    私有类
    private double size;
    private int age;

    public void call(){
        System.out.println("手机在打电话");
    }
    public void playGame(){
        System.out.println("手机在打游戏");
    }
//    对私有类的调用
    public void setSize(double s){
        size = s;
    }
    public double getSize(){
        return size;
    }

    /***
     * 多个age的 就近原则
     */
    public void addAge(){
        int age = 11;
        System.out.println(age);
        this.age = 22;
        System.out.println(this.age);
    }

}
